package com.example.springcloud.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.example.springcloud.mapper.PathMapper;
import com.example.springcloud.domain.Path;
import com.example.springcloud.service.IPathService;

/**
 * 途径点Service业务层处理
 * 
 * @author helian
 * @date 2025-03-01
 */
@Service
public class PathServiceImpl implements IPathService 
{
    @Autowired
    private PathMapper pathMapper;

    /**
     * 查询途径点
     * 
     * @param id 途径点主键
     * @return 途径点
     */
    @Override
    public Path selectPathById(Long id)
    {
        return pathMapper.selectPathById(id);
    }

    /**
     * 查询途径点列表
     * 
     * @param path 途径点
     * @return 途径点
     */
    @Override
    public List<Path> selectPathList(Path path)
    {
        return pathMapper.selectPathList(path);
    }

    /**
     * 新增途径点
     * 
     * @param path 途径点
     * @return 结果
     */
    @Override
    public int insertPath(Path path)
    {
        return pathMapper.insertPath(path);
    }

    /**
     * 修改途径点
     * 
     * @param path 途径点
     * @return 结果
     */
    @Override
    public int updatePath(Path path)
    {
        return pathMapper.updatePath(path);
    }

    /**
     * 批量删除途径点
     * 
     * @param ids 需要删除的途径点主键
     * @return 结果
     */
    @Override
    public int deletePathByIds(Long[] ids)
    {
        return pathMapper.deletePathByIds(ids);
    }

    /**
     * 删除途径点信息
     * 
     * @param id 途径点主键
     * @return 结果
     */
    @Override
    public int deletePathById(Long id)
    {
        return pathMapper.deletePathById(id);
    }
}
